<!-- 地图控件 -- 丁翔 -- 2017年4月25日 星期二 -->
<template>
  <div style="width: 158px; height: 30px; " name="city">
    <el-input v-model="input" placeholder="城市名" type="text" class="el-input el-input--small" style="width: 158px"
              @focus="indication" @input="indication" @keyup.down.native.prevent="downSelect"
              @keyup.up.native.prevent="upSelect" @keyup.enter.native.prevent="enterSelect"
              name="city"></el-input>
    <div id="cityBody" ref="cityBody" name="city" v-show="isShowCityBody" style="position:absolute">
      <div style="padding: 10px 10px 10px 10px;">
        <div style="padding-left: 10px;color: #bfcbd9" name="city">热门城市（可直接选择城市或输入城市中文/拼音）
          <el-button type="danger" :plain="true" icon="close" size="mini" style="float: right;"
                     @click="conceal" name="city"></el-button>
        </div>
        <el-tabs v-model="activeName" @tab-click="handleClick" name="city">
          <el-tab-pane label="热门" name="first" style="padding-left: 60px">
            <div class="city-content bg-purple" v-for="hot in hotCity"
                 @click="evaluationInput(hot.cityName,hot.spell,hot.abbreviate)" name="city">{{hot.cityName}}
            </div>
          </el-tab-pane>
          <el-tab-pane label="ABCD" name="second" >
            <div class="city-div" name="city">
              <div class="city-frist" name="city">A</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='A'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">B</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='B'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">C</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='C'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">D</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='D'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
          </el-tab-pane>
          <el-tab-pane label="EFGH" name="third" >
            <div class="city-div" name="city">
              <div class="city-frist" name="city">E</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='E'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">F</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='F'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">G</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='G'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">H</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='H'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
          </el-tab-pane>
          <el-tab-pane label="JKL" name="fourth" >
             <div class="city-div" name="city">
              <div class="city-frist" name="city">J</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='J'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">K</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='K'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">L</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='L'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
          </el-tab-pane>
          <el-tab-pane label="MNPQ" name="fifth">
            <div class="city-div" name="city">
              <div class="city-frist" name="city">M</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='M'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">N</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='N'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">P</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='P'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">Q</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='Q'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
          </el-tab-pane>
          <el-tab-pane label="STW" name="sixth">
            <div class="city-div" name="city">
              <div class="city-frist" name="city">S</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='S'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">T</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='T'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">W</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='W'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
          </el-tab-pane>
          <el-tab-pane label="XYZ" name="seventh">
            <div class="city-div" name="city">
              <div class="city-frist" name="city">X</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='X'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">Y</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='Y'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
            <div class="city-div" name="city">
              <div class="city-frist" name="city">Z</div>
              <div style="width: 94%;float: right;" name="city">
                <div class="city-content bg-purple" v-for="c in city"
                     @click="evaluationInput(c.cityName,c.spell,c.abbreviate)" v-if="c.initial=='Z'" name="city">
                  {{c.cityName}}
                </div>
              </div>
            </div>
          </el-tab-pane>
        </el-tabs>
      </div>
    </div>
    <div id="cityNameBody" name="city" style="z-index:10;position:absolute" v-show="isShowCityNameBody">
      <div style="padding: 10px 10px 10px 10px;">
        <div style="padding-left: 10px;color: #bfcbd9;" name="city">输入中文/拼音/↑↓键选择
          <el-button type="danger" :plain="true" icon="close" size="mini" style="float: right;"
                     @click="conceal" name="city"></el-button>
        </div>
        <div style="padding-left: 10px;color: #bfcbd9;border-bottom:solid 1px #bfcbd9;margin-top: 10px"
             name="city"></div>
        <div class="city-select" v-for="(sCity,index) in selectCity"
             :style="{'background-color': index === 0 ? '#bfcbd9' : ''}" @click="evaluation(sCity.cityName)"
             v-on:mouseenter="mover(index)" name="city">
          <span class="city-name" name="city">
            {{sCity.cityName}}
          </span>
          <span class="city-spell" name="city">
            {{sCity.spell}}
          </span>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
  import $ from 'jquery'
  export default {
    props: {
      initCity: String,
      flag: Boolean
    },
    data () {
      return {
        isShowCityBody: false, // 是否显示城市插件
        isShowCityNameBody: false,
        activeName: 'first',
        input: '',
        keyIndex: 0,
        hotCity: [
          {
            cityName: '北京',
            spell: 'BeiJing',
            abbreviate: 'BJ'
          }, {
            cityName: '上海',
            spell: 'ShangHai',
            abbreviate: 'SH'
          }, {
            cityName: '杭州',
            spell: 'HangZhou',
            abbreviate: 'HZ'
          }, {
            cityName: '广州',
            spell: 'GuangZhou',
            abbreviate: 'GZ'
          }, {
            cityName: '深圳',
            spell: 'ShenZhen',
            abbreviate: 'SZ'
          }, {
            cityName: '成都',
            spell: 'ChengDu',
            abbreviate: 'CD'
          }, {
            cityName: '西安',
            spell: 'XiAn',
            abbreviate: 'XA'
          }, {
            cityName: '武汉',
            spell: 'WuHan',
            abbreviate: 'WH'
          }, {
            cityName: '长沙',
            spell: 'ChangSha',
            abbreviate: 'CS'
          }, {
            cityName: '重庆',
            spell: 'ChongQing',
            abbreviate: 'CQ'
          }, {
            cityName: '青岛',
            spell: 'QingDao',
            abbreviate: 'QD'
          }, {
            cityName: '南京',
            spell: 'NanJing',
            abbreviate: 'NJ'
          }, {
            cityName: '厦门',
            spell: 'XiaMen',
            abbreviate: 'XM'
          }, {
            cityName: '昆明',
            spell: 'KunMing',
            abbreviate: 'KM'
          }, {
            cityName: '大连',
            spell: 'DaLian',
            abbreviate: 'DL'
          }, {
            cityName: '三亚',
            spell: 'SanYa',
            abbreviate: 'SY'
          }, {
            cityName: '天津',
            spell: 'tianjin',
            abbreviate: 'TJ'
          }, {
            cityName: '哈尔滨',
            spell: 'HaErBin',
            abbreviate: 'HEB'
          }, {
            cityName: '呼和浩特',
            spell: 'HuHeHaoTe',
            abbreviate: 'HHHT'
          }, {
            cityName: '温州',
            spell: 'WenZhou',
            abbreviate: 'WZ'
          }, {
            cityName: '贵阳',
            spell: 'GueiYang',
            abbreviate: 'GY'
          }, {
            cityName: '沈阳',
            spell: 'ShenYang',
            abbreviate: 'SY'
          }, {
            cityName: '南海',
            spell: 'NanHai',
            abbreviate: 'NH'
          }, {
            cityName: '定西',
            spell: 'DingXi',
            abbreviate: 'DX'
          }, {
            cityName: '白银',
            spell: 'BaiYin',
            abbreviate: 'BY'
          }
        ],
        city: [{
          cityName: '阿勒泰', spell: 'ALeTai', abbreviate: 'ALT', initial: 'A'
        }, {
          cityName: '安康', spell: 'AnKang', abbreviate: 'AK', initial: 'A'
        }, {
          cityName: '阿克苏', spell: 'AKeSu', abbreviate: 'AKS', initial: 'A'
        }, {
          cityName: '鞍山', spell: 'AnShan', abbreviate: 'AS', initial: 'A'
        }, {
          cityName: '安庆', spell: 'AnQing', abbreviate: 'AQ', initial: 'A'
        }, {
          cityName: '安顺', spell: 'AnShun', abbreviate: 'AS', initial: 'A'
        }, {
          cityName: '安阳', spell: 'AnYang', abbreviate: 'AY', initial: 'A'
        }, {
          cityName: '阿里', spell: 'ALi', abbreviate: 'AL', initial: 'A'
        }, {
          cityName: '阿尔山', spell: 'AErShan', abbreviate: 'AES', initial: 'A'
        }, {
          cityName: '阿拉善左旗', spell: 'ALaShanZuoQi', abbreviate: 'ALSZQ', initial: 'A'
        }, {
          cityName: '阿拉尔', spell: 'ALaEr', abbreviate: 'ALE', initial: 'A'
        }, {
          cityName: '安吉', spell: 'AnJi', abbreviate: 'AJ', initial: 'A'
        }, {
          cityName: '阿图什', spell: 'ATuShen', abbreviate: 'ATS', initial: 'A'
        }, {
          cityName: '阿拉善右旗', spell: 'ALaShanYouQi', abbreviate: 'ALSYQ', initial: 'A'
        }, {
          cityName: '博乐', spell: 'BoLe', abbreviate: 'BL', initial: 'B'
        }, {
          cityName: '百色', spell: 'BaiSe', abbreviate: 'BS', initial: 'B'
        }, {
          cityName: '包头', spell: 'BaoTou', abbreviate: 'BT', initial: 'B'
        }, {
          cityName: '蚌埠', spell: 'BangBu', abbreviate: 'BB', initial: 'B'
        }, {
          cityName: '北海', spell: 'BeiHai', abbreviate: 'BH', initial: 'B'
        }, {
          cityName: '邦达', spell: 'BangDa', abbreviate: 'BD', initial: 'B'
        }, {
          cityName: '保山', spell: 'BaoShan', abbreviate: 'BS', initial: 'B'
        }, {
          cityName: '北京首都', spell: 'BeiJingShouDou', abbreviate: 'BJSD', initial: 'B'
        }, {
          cityName: '北京南苑', spell: 'BeiJingNanYuan', abbreviate: 'BJNY', initial: 'B'
        }, {
          cityName: '巴彦淖尔', spell: 'BaYanNaoEr', abbreviate: 'BYNE', initial: 'B'
        }, {
          cityName: '北京', spell: 'BeiJing', abbreviate: 'BJ', initial: 'B'
        }, {
          cityName: '白银', spell: 'BaiYin', abbreviate: 'BY', initial: 'B'
        }, {
          cityName: '亳州', spell: 'BoZhou', abbreviate: 'BZ', initial: 'B'
        }, {
          cityName: '保亭', spell: 'BaoTing', abbreviate: 'BT', initial: 'B'
        }, {
          cityName: '白沙', spell: 'BaiSha', abbreviate: 'BS', initial: 'B'
        }, {
          cityName: '本溪', spell: 'BenXi', abbreviate: 'BX', initial: 'B'
        }, {
          cityName: '滨州', spell: 'BinZhou', abbreviate: 'BZ', initial: 'B'
        }, {
          cityName: '巴中', spell: 'BaZhong', abbreviate: 'BZ', initial: 'B'
        }, {
          cityName: '保定', spell: 'BaoDing', abbreviate: 'BD', initial: 'B'
        }, {
          cityName: '博鳌', spell: 'BoAo', abbreviate: 'BA', initial: 'B'
        }, {
          cityName: '白城', spell: 'BaiCheng', abbreviate: 'BC', initial: 'B'
        }, {
          cityName: '宝鸡', spell: 'BaoJi', abbreviate: 'BJ', initial: 'B'
        }, {
          cityName: '毕节', spell: 'BiJie', abbreviate: 'BJ', initial: 'B'
        }, {
          cityName: '池州', spell: 'ChiZhou', abbreviate: 'CZ', initial: 'C'
        }, {
          cityName: '沧源', spell: 'CangYuan', abbreviate: 'CY', initial: 'C'
        }, {
          cityName: '常德', spell: 'ChangDe', abbreviate: 'CD', initial: 'C'
        }, {
          cityName: '朝阳', spell: 'ChaoYang', abbreviate: 'CY', initial: 'C'
        }, {
          cityName: '赤峰', spell: 'ChiFeng', abbreviate: 'CF', initial: 'C'
        }, {
          cityName: '成都', spell: 'ChengDou', abbreviate: 'CD', initial: 'C'
        }, {
          cityName: '常州', spell: 'ChangZhou', abbreviate: 'CZ', initial: 'C'
        }, {
          cityName: '潮州', spell: 'ChaoZhou', abbreviate: 'CZ', initial: 'C'
        }, {
          cityName: '崇左', spell: 'ChongZuo', abbreviate: 'CZ', initial: 'C'
        }, {
          cityName: '昌江', spell: 'ChangJiang', abbreviate: 'CJ', initial: 'C'
        }, {
          cityName: '澄迈', spell: 'ChengMai', abbreviate: 'CM', initial: 'C'
        }, {
          cityName: '承德', spell: 'ChengDe', abbreviate: 'CD', initial: 'C'
        }, {
          cityName: '巢湖', spell: 'ChaoHu', abbreviate: 'CH', initial: 'C'
        }, {
          cityName: '沧州', spell: 'CangZhou', abbreviate: 'CZ', initial: 'C'
        }, {
          cityName: '滁州', spell: 'ChuZhou', abbreviate: 'CZ', initial: 'C'
        }, {
          cityName: '郴州', spell: 'ChenZhou', abbreviate: 'CZ', initial: 'C'
        }, {
          cityName: '昌都', spell: 'ChangDou', abbreviate: 'CD', initial: 'C'
        }, {
          cityName: '昌吉', spell: 'ChangJi', abbreviate: 'CJ', initial: 'C'
        }, {
          cityName: '常熟', spell: 'ChangShu', abbreviate: 'CS', initial: 'C'
        }, {
          cityName: '慈溪', spell: 'CiXi', abbreviate: 'CX', initial: 'C'
        }, {
          cityName: '昌黎', spell: 'ChangLi', abbreviate: 'CL', initial: 'C'
        }, {
          cityName: '从化', spell: 'CongHua', abbreviate: 'CH', initial: 'C'
        }, {
          cityName: '定西', spell: 'DingXi', abbreviate: 'DX', initial: 'D'
        }, {
          cityName: '东方', spell: 'DongFang', abbreviate: 'DF', initial: 'D'
        }, {
          cityName: '定安', spell: 'DingAn', abbreviate: 'DA', initial: 'D'
        }, {
          cityName: '大庸', spell: 'DaYong', abbreviate: 'DY', initial: 'D'
        }, {
          cityName: '达州', spell: 'DaZhou', abbreviate: 'DZ', initial: 'D'
        }, {
          cityName: '德令哈', spell: 'DeLingHa', abbreviate: 'DLH', initial: 'D'
        }, {
          cityName: '稻城', spell: 'DaoCheng', abbreviate: 'DC', initial: 'D'
        }, {
          cityName: '东阳', spell: 'DongYang', abbreviate: 'DY', initial: 'D'
        }, {
          cityName: '德清', spell: 'DeQing', abbreviate: 'DQ', initial: 'D'
        }, {
          cityName: '大兴', spell: 'DaXing', abbreviate: 'DX', initial: 'D'
        }, {
          cityName: '都江堰', spell: 'DouJiangYan', abbreviate: 'DJY', initial: 'D'
        }, {
          cityName: '大庆', spell: 'DaQing', abbreviate: 'DQ', initial: 'D'
        }, {
          cityName: '丹阳', spell: 'DanYang', abbreviate: 'DY', initial: 'D'
        }, {
          cityName: '德州', spell: 'DeZhou', abbreviate: 'DZ', initial: 'D'
        }, {
          cityName: '大同', spell: 'DaTong', abbreviate: 'DT', initial: 'D'
        }, {
          cityName: '达县', spell: 'DaXian', abbreviate: 'DX', initial: 'D'
        }, {
          cityName: '丹东', spell: 'DanDong', abbreviate: 'DD', initial: 'D'
        }, {
          cityName: '东莞', spell: 'DongGuan', abbreviate: 'DG', initial: 'D'
        }, {
          cityName: '迪庆', spell: 'DiQing', abbreviate: 'DQ', initial: 'D'
        }, {
          cityName: '大连', spell: 'DaLian', abbreviate: 'DL', initial: 'D'
        }, {
          cityName: '大理', spell: 'DaLi', abbreviate: 'DL', initial: 'D'
        }, {
          cityName: '敦煌', spell: 'DunHuang', abbreviate: 'DH', initial: 'D'
        }, {
          cityName: '东营', spell: 'DongYing', abbreviate: 'DY', initial: 'D'
        }, {
          cityName: '大足', spell: 'DaZu', abbreviate: 'DZ', initial: 'D'
        }, {
          cityName: '儋州', spell: 'DanZhou', abbreviate: 'DZ', initial: 'D'
        }, {
          cityName: '鄂州', spell: 'EZhou', abbreviate: 'EZ', initial: 'E'
        }, {
          cityName: '恩平', spell: 'EnPing', abbreviate: 'EP', initial: 'E'
        }, {
          cityName: '峨眉山', spell: 'EMeiShan', abbreviate: 'EMS', initial: 'E'
        }, {
          cityName: '额济纳', spell: 'EJiNa', abbreviate: 'EJN', initial: 'E'
        }, {
          cityName: '鄂尔多斯', spell: 'EErDuoSi', abbreviate: 'EEDS', initial: 'E'
        }, {
          cityName: '恩施', spell: 'EnShi', abbreviate: 'ES', initial: 'E'
        }, {
          cityName: '二连浩特', spell: 'ErLianHaoTe', abbreviate: 'ELHT', initial: 'E'
        }, {
          cityName: '防城港', spell: 'FangChengGang', abbreviate: 'FCG', initial: 'F'
        }, {
          cityName: '阜新', spell: 'FuXin', abbreviate: 'FX', initial: 'F'
        }, {
          cityName: '抚顺', spell: 'FuShun', abbreviate: 'FS', initial: 'F'
        }, {
          cityName: '抚远', spell: 'FuYuan', abbreviate: 'FY', initial: 'F'
        }, {
          cityName: '奉化', spell: 'FengHua', abbreviate: 'FH', initial: 'F'
        }, {
          cityName: '福鼎', spell: 'FuDing', abbreviate: 'FD', initial: 'F'
        }, {
          cityName: '凤凰', spell: 'FengHuang', abbreviate: 'FH', initial: 'F'
        }, {
          cityName: '防城', spell: 'FangCheng', abbreviate: 'FC', initial: 'F'
        }, {
          cityName: '福州', spell: 'FuZhou', abbreviate: 'FZ', initial: 'F'
        }, {
          cityName: '阜阳', spell: 'FuYang', abbreviate: 'FY', initial: 'F'
        }, {
          cityName: '佛山', spell: 'FoShan', abbreviate: 'FS', initial: 'F'
        }, {
          cityName: '富蕴', spell: 'FuYun', abbreviate: 'FY', initial: 'F'
        }, {
          cityName: '固原', spell: 'GuYuan', abbreviate: 'GY', initial: 'G'
        }, {
          cityName: '甘南', spell: 'GanNan', abbreviate: 'GN', initial: 'G'
        }, {
          cityName: '贵港', spell: 'GuiGang', abbreviate: 'GG', initial: 'G'
        }, {
          cityName: '广安', spell: 'GuangAn', abbreviate: 'GA', initial: 'G'
        }, {
          cityName: '广州', spell: 'GuangZhou', abbreviate: 'GZ', initial: 'G'
        }, {
          cityName: '广汉', spell: 'GuangHan', abbreviate: 'GH', initial: 'G'
        }, {
          cityName: '格尔木', spell: 'GeErMu', abbreviate: 'GEM', initial: 'G'
        }, {
          cityName: '高崎', spell: 'GaoQi', abbreviate: 'GQ', initial: 'G'
        }, {
          cityName: '广元', spell: 'GuangYuan', abbreviate: 'GY', initial: 'G'
        }, {
          cityName: '赣州', spell: 'GanZhou', abbreviate: 'GZ', initial: 'G'
        }, {
          cityName: '贵阳', spell: 'GuiYang', abbreviate: 'GY', initial: 'G'
        }, {
          cityName: '桂林', spell: 'GuiLin', abbreviate: 'GL', initial: 'G'
        }, {
          cityName: '光化', spell: 'GuangHua', abbreviate: 'GH', initial: 'G'
        }, {
          cityName: '河源', spell: 'HeYuan', abbreviate: 'HY', initial: 'H'
        }, {
          cityName: '贺州', spell: 'HeZhou', abbreviate: 'HZ', initial: 'H'
        }, {
          cityName: '衡水', spell: 'HengShui', abbreviate: 'HS', initial: 'H'
        }, {
          cityName: '鹤岗', spell: 'HeGang', abbreviate: 'HG', initial: 'H'
        }, {
          cityName: '黄冈', spell: 'HuangGang', abbreviate: 'HG', initial: 'H'
        }, {
          cityName: '黄南', spell: 'HuangNan', abbreviate: 'HN', initial: 'H'
        }, {
          cityName: '海南藏族', spell: 'HaiNanZangZu', abbreviate: 'HNZZ', initial: 'H'
        }, {
          cityName: '海东', spell: 'HaiDong', abbreviate: 'HD', initial: 'H'
        }, {
          cityName: '海北', spell: 'HaiBei', abbreviate: 'HB', initial: 'H'
        }, {
          cityName: '菏泽', spell: 'HeZe', abbreviate: 'HZ', initial: 'H'
        }, {
          cityName: '淮北', spell: 'HuaiBei', abbreviate: 'HB', initial: 'H'
        }, {
          cityName: '鹤壁', spell: 'HeBi', abbreviate: 'HB', initial: 'H'
        }, {
          cityName: '淮南', spell: 'HuaiNan', abbreviate: 'HN', initial: 'H'
        }, {
          cityName: '河池', spell: 'HeChi', abbreviate: 'HC', initial: 'H'
        }, {
          cityName: '红河', spell: 'HongHe', abbreviate: 'HH', initial: 'H'
        }, {
          cityName: '海盐', spell: 'HaiYan', abbreviate: 'HY', initial: 'H'
        }, {
          cityName: '海城', spell: 'HaiCheng', abbreviate: 'HC', initial: 'H'
        }, {
          cityName: '海宁', spell: 'HaiNing', abbreviate: 'HN', initial: 'H'
        }, {
          cityName: '湖州', spell: 'HuZhou', abbreviate: 'HZ', initial: 'H'
        }, {
          cityName: '葫芦岛', spell: 'HuLuDao', abbreviate: 'HLD', initial: 'H'
        }, {
          cityName: '呼伦贝尔', spell: 'HuLunBeiEr', abbreviate: 'HLBE', initial: 'H'
        }, {
          cityName: '红原', spell: 'HongYuan', abbreviate: 'HY', initial: 'H'
        }, {
          cityName: '海口', spell: 'HaiKou', abbreviate: 'HK', initial: 'H'
        }, {
          cityName: '邯郸', spell: 'HanDan', abbreviate: 'HD', initial: 'H'
        }, {
          cityName: '黑河', spell: 'HeiHe', abbreviate: 'HH', initial: 'H'
        }, {
          cityName: '呼和浩特', spell: 'HuHeHaoTe', abbreviate: 'HHHT', initial: 'H'
        }, {
          cityName: '合肥', spell: 'HeFei', abbreviate: 'HF', initial: 'H'
        }, {
          cityName: '杭州', spell: 'HangZhou', abbreviate: 'HZ', initial: 'H'
        }, {
          cityName: '怀化', spell: 'HuaiHua', abbreviate: 'HH', initial: 'H'
        }, {
          cityName: '海拉尔', spell: 'HaiLaEr', abbreviate: 'HLE', initial: 'H'
        }, {
          cityName: '哈密', spell: 'HaMi', abbreviate: 'HM', initial: 'H'
        }, {
          cityName: '衡阳', spell: 'HengYang', abbreviate: 'HY', initial: 'H'
        }, {
          cityName: '哈尔滨', spell: 'HaErBin', abbreviate: 'HEB', initial: 'H'
        }, {
          cityName: '和田', spell: 'HeTian', abbreviate: 'HT', initial: 'H'
        }, {
          cityName: '惠州', spell: 'HuiZhou', abbreviate: 'HZ', initial: 'H'
        }, {
          cityName: '黄岩', spell: 'HuangYan', abbreviate: 'HY', initial: 'H'
        }, {
          cityName: '汉中', spell: 'HanZhong', abbreviate: 'HZ', initial: 'H'
        }, {
          cityName: '淮安', spell: 'HuaiAn', abbreviate: 'HA', initial: 'H'
        }, {
          cityName: '黄山', spell: 'HuangShan', abbreviate: 'HS', initial: 'H'
        }, {
          cityName: '黄石', spell: 'HuangShi', abbreviate: 'HS', initial: 'H'
        }, {
          cityName: '鸡西', spell: 'JiXi', abbreviate: 'JX', initial: 'J'
        }, {
          cityName: '酒泉', spell: 'JiuQuan', abbreviate: 'JQ', initial: 'J'
        }, {
          cityName: '江门', spell: 'JiangMen', abbreviate: 'JM', initial: 'J'
        }, {
          cityName: '焦作', spell: 'JiaoZuo', abbreviate: 'JZ', initial: 'J'
        }, {
          cityName: '济源', spell: 'JiYuan', abbreviate: 'JY', initial: 'J'
        }, {
          cityName: '荆门', spell: 'JingMen', abbreviate: 'JM', initial: 'J'
        }, {
          cityName: '晋中', spell: 'JinZhong', abbreviate: 'JZ', initial: 'J'
        }, {
          cityName: '吉林', spell: 'JiLin', abbreviate: 'JL', initial: 'J'
        }, {
          cityName: '揭阳', spell: 'JieYang', abbreviate: 'JY', initial: 'J'
        }, {
          cityName: '景洪', spell: 'JingHong', abbreviate: 'JH', initial: 'J'
        }, {
          cityName: '加格达奇', spell: 'JiaGeDaQi', abbreviate: 'JGDQ', initial: 'J'
        }, {
          cityName: '江都', spell: 'JiangDou', abbreviate: 'JD', initial: 'J'
        }, {
          cityName: '建德', spell: 'JianDe', abbreviate: 'JD', initial: 'J'
        }, {
          cityName: '缙云', spell: 'JinYun', abbreviate: 'JY', initial: 'J'
        }, {
          cityName: '胶州', spell: 'JiaoZhou', abbreviate: 'JZ', initial: 'J'
        }, {
          cityName: '荆州', spell: 'JingZhou', abbreviate: 'JZ', initial: 'J'
        }, {
          cityName: '金昌', spell: 'JinChang', abbreviate: 'JC', initial: 'J'
        }, {
          cityName: '九华山', spell: 'JiuHuaShan', abbreviate: 'JHS', initial: 'J'
        }, {
          cityName: '嘉善', spell: 'JiaShan', abbreviate: 'JS', initial: 'J'
        }, {
          cityName: '江阴', spell: 'JiangYin', abbreviate: 'JY', initial: 'J'
        }, {
          cityName: '金华', spell: 'JinHua', abbreviate: 'JH', initial: 'J'
        }, {
          cityName: '嘉兴', spell: 'JiaXing', abbreviate: 'JX', initial: 'J'
        }, {
          cityName: '景德镇', spell: 'JingDeZhen', abbreviate: 'JDZ', initial: 'J'
        }, {
          cityName: '嘉峪关', spell: 'JiaYuGuan', abbreviate: 'JYG', initial: 'J'
        }, {
          cityName: '井冈山', spell: 'JingGangShan', abbreviate: 'JGS', initial: 'J'
        }, {
          cityName: '吉林市', spell: 'JiLinShi', abbreviate: 'JLS', initial: 'J'
        }, {
          cityName: '九江', spell: 'JiuJiang', abbreviate: 'JJ', initial: 'J'
        }, {
          cityName: '晋江', spell: 'JinJiang', abbreviate: 'JJ', initial: 'J'
        }, {
          cityName: '佳木斯', spell: 'JiaMuSi', abbreviate: 'JMS', initial: 'J'
        }, {
          cityName: '济宁', spell: 'JiNing', abbreviate: 'JN', initial: 'J'
        }, {
          cityName: '锦州', spell: 'JinZhou', abbreviate: 'JZ', initial: 'J'
        }, {
          cityName: '九寨沟', spell: 'JiuZhaiGou', abbreviate: 'JZG', initial: 'J'
        }, {
          cityName: '吉安', spell: 'JiAn', abbreviate: 'JA', initial: 'J'
        }, {
          cityName: '济南', spell: 'JiNan', abbreviate: 'JN', initial: 'J'
        }, {
          cityName: '康定', spell: 'KangDing', abbreviate: 'KD', initial: 'K'
        }, {
          cityName: '开封', spell: 'KaiFeng', abbreviate: 'KF', initial: 'K'
        }, {
          cityName: '凯里', spell: 'KaiLi', abbreviate: 'KL', initial: 'K'
        }, {
          cityName: '开平', spell: 'KaiPing', abbreviate: 'KP', initial: 'K'
        }, {
          cityName: '奎屯', spell: 'KuiTun', abbreviate: 'KT', initial: 'K'
        }, {
          cityName: '昆山', spell: 'KunShan', abbreviate: 'KS', initial: 'K'
        }, {
          cityName: '库车', spell: 'KuChe', abbreviate: 'KC', initial: 'K'
        }, {
          cityName: '喀什', spell: 'KaShen', abbreviate: 'KS', initial: 'K'
        }, {
          cityName: '喀纳斯', spell: 'KaNaSi', abbreviate: 'KNS', initial: 'K'
        }, {
          cityName: '昆明', spell: 'KunMing', abbreviate: 'KM', initial: 'K'
        }, {
          cityName: '库尔勒', spell: 'KuErLe', abbreviate: 'KEL', initial: 'K'
        }, {
          cityName: '克拉玛依', spell: 'KeLaMaYi', abbreviate: 'KLMY', initial: 'K'
        }, {
          cityName: '凯里黄平', spell: 'KaiLiHuangPing', abbreviate: 'KLHP', initial: 'K'
        }, {
          cityName: '柳州', spell: 'LiuZhou', abbreviate: 'LZ', initial: 'L'
        }, {
          cityName: '荔波', spell: 'LiBo', abbreviate: 'LB', initial: 'L'
        }, {
          cityName: '陇南', spell: 'LongNan', abbreviate: 'LN', initial: 'L'
        }, {
          cityName: '临夏', spell: 'LinXia', abbreviate: 'LX', initial: 'L'
        }, {
          cityName: '来宾', spell: 'LaiBin', abbreviate: 'LB', initial: 'L'
        }, {
          cityName: '临高', spell: 'LinGao', abbreviate: 'LG', initial: 'L'
        }, {
          cityName: '乐东', spell: 'LeDong', abbreviate: 'LD', initial: 'L'
        }, {
          cityName: '廊坊', spell: 'LangFang', abbreviate: 'LF', initial: 'L'
        }, {
          cityName: '漯河', spell: 'LuoHe', abbreviate: 'LH', initial: 'L'
        }, {
          cityName: '娄底', spell: 'LouDi', abbreviate: 'LD', initial: 'L'
        }, {
          cityName: '辽源', spell: 'LiaoYuan', abbreviate: 'LY', initial: 'L'
        }, {
          cityName: '辽阳', spell: 'LiaoYang', abbreviate: 'LY', initial: 'L'
        }, {
          cityName: '聊城', spell: 'LiaoCheng', abbreviate: 'LC', initial: 'L'
        }, {
          cityName: '莱芜', spell: 'LaiWu', abbreviate: 'LW', initial: 'L'
        }, {
          cityName: '乐山', spell: 'LeShan', abbreviate: 'LS', initial: 'L'
        }, {
          cityName: '临汾', spell: 'LinFen', abbreviate: 'LF', initial: 'L'
        }, {
          cityName: '六安', spell: 'LiuAn', abbreviate: 'LA', initial: 'L'
        }, {
          cityName: '陵水', spell: 'LingShui', abbreviate: 'LS', initial: 'L'
        }, {
          cityName: '丽水', spell: 'LiShui', abbreviate: 'LS', initial: 'L'
        }, {
          cityName: '六盘水', spell: 'LiuPanShui', abbreviate: 'LPS', initial: 'L'
        }, {
          cityName: '吕梁', spell: 'LvLiang', abbreviate: 'LL', initial: 'L'
        }, {
          cityName: '溧阳', spell: 'LiYang', abbreviate: 'LY', initial: 'L'
        }, {
          cityName: '临安', spell: 'LinAn', abbreviate: 'LA', initial: 'L'
        }, {
          cityName: '黎平', spell: 'LiPing', abbreviate: 'LP', initial: 'L'
        }, {
          cityName: '兰溪', spell: 'LanXi', abbreviate: 'LX', initial: 'L'
        }, {
          cityName: '临海', spell: 'LinHai', abbreviate: 'LH', initial: 'L'
        }, {
          cityName: '龙游', spell: 'LongYou', abbreviate: 'LY', initial: 'L'
        }, {
          cityName: '滦平', spell: 'LuanPing', abbreviate: 'LP', initial: 'L'
        }, {
          cityName: '莱西', spell: 'LaiXi', abbreviate: 'LX', initial: 'L'
        }, {
          cityName: '阆中', spell: 'LangZhong', abbreviate: 'LZ', initial: 'L'
        }, {
          cityName: '龙岩', spell: 'LongYan', abbreviate: 'LY', initial: 'L'
        }, {
          cityName: '连城', spell: 'LianCheng', abbreviate: 'LC', initial: 'L'
        }, {
          cityName: '兰州', spell: 'LanZhou', abbreviate: 'LZ', initial: 'L'
        }, {
          cityName: '梁平', spell: 'LiangPing', abbreviate: 'LP', initial: 'L'
        }, {
          cityName: '丽江', spell: 'LiJiang', abbreviate: 'LJ', initial: 'L'
        }, {
          cityName: '临沧', spell: 'LinCang', abbreviate: 'LC', initial: 'L'
        }, {
          cityName: '庐山', spell: 'LuShan', abbreviate: 'LS', initial: 'L'
        }, {
          cityName: '拉萨', spell: 'LaSa', abbreviate: 'LS', initial: 'L'
        }, {
          cityName: '林西', spell: 'LinXi', abbreviate: 'LX', initial: 'L'
        }, {
          cityName: '洛阳', spell: 'LuoYang', abbreviate: 'LY', initial: 'L'
        }, {
          cityName: '连云港', spell: 'LianYunGang', abbreviate: 'LYG', initial: 'L'
        }, {
          cityName: '临沂', spell: 'LinYi', abbreviate: 'LY', initial: 'L'
        }, {
          cityName: '泸州', spell: 'LuZhou', abbreviate: 'LZ', initial: 'L'
        }, {
          cityName: '林芝', spell: 'LinZhi', abbreviate: 'LZ', initial: 'L'
        }, {
          cityName: '漠河', spell: 'MoHe', abbreviate: 'MH', initial: 'M'
        }, {
          cityName: '满洲里', spell: 'ManZhouLi', abbreviate: 'MZL', initial: 'M'
        }, {
          cityName: '茂名', spell: 'MaoMing', abbreviate: 'MM', initial: 'M'
        }, {
          cityName: '眉山', spell: 'MeiShan', abbreviate: 'MS', initial: 'M'
        }, {
          cityName: '马鞍山', spell: 'MaAnShan', abbreviate: 'MAS', initial: 'M'
        }, {
          cityName: '梅州', spell: 'MeiZhou', abbreviate: 'MZ', initial: 'M'
        }, {
          cityName: '绵竹', spell: 'MianZhu', abbreviate: 'MZ', initial: 'M'
        }, {
          cityName: '芒市', spell: 'MangShi', abbreviate: 'MS', initial: 'M'
        }, {
          cityName: '牡丹江', spell: 'MuDanJiang', abbreviate: 'MDJ', initial: 'M'
        }, {
          cityName: '绵阳', spell: 'MianYang', abbreviate: 'MY', initial: 'M'
        }, {
          cityName: '梅县', spell: 'MeiXian', abbreviate: 'MX', initial: 'M'
        }, {
          cityName: '宁波', spell: 'NingBo', abbreviate: 'NB', initial: 'N'
        }, {
          cityName: '南京', spell: 'NanJing', abbreviate: 'NJ', initial: 'N'
        }, {
          cityName: '那拉提', spell: 'NeiLaTi', abbreviate: 'NLT', initial: 'N'
        }, {
          cityName: '南宁', spell: 'NanNing', abbreviate: 'NN', initial: 'N'
        }, {
          cityName: '南阳', spell: 'NanYang', abbreviate: 'NY', initial: 'N'
        }, {
          cityName: '南通', spell: 'NanTong', abbreviate: 'NT', initial: 'N'
        }, {
          cityName: '南竿', spell: 'NanGan', abbreviate: 'NG', initial: 'N'
        }, {
          cityName: '南海', spell: 'NanHai', abbreviate: 'NH', initial: 'N'
        }, {
          cityName: '内江', spell: 'NeiJiang', abbreviate: 'NJ', initial: 'N'
        }, {
          cityName: '宁蒗', spell: 'NingLang', abbreviate: 'NL', initial: 'N'
        }, {
          cityName: '宁德', spell: 'NingDe', abbreviate: 'ND', initial: 'N'
        }, {
          cityName: '那曲', spell: 'NeiQu', abbreviate: 'NQ', initial: 'N'
        }, {
          cityName: '怒江', spell: 'NuJiang', abbreviate: 'NJ', initial: 'N'
        }, {
          cityName: '宁海', spell: 'NingHai', abbreviate: 'NH', initial: 'N'
        }, {
          cityName: '南昌', spell: 'NanChang', abbreviate: 'NC', initial: 'N'
        }, {
          cityName: '南沙', spell: 'NanSha', abbreviate: 'NS', initial: 'N'
        }, {
          cityName: '南充', spell: 'NanChong', abbreviate: 'NC', initial: 'N'
        }, {
          cityName: '蓬莱', spell: 'PengLai', abbreviate: 'PL', initial: 'P'
        }, {
          cityName: '攀枝花', spell: 'PanZhiHua', abbreviate: 'PZH', initial: 'P'
        }, {
          cityName: '莆田', spell: 'PuTian', abbreviate: 'PT', initial: 'P'
        }, {
          cityName: '平凉', spell: 'PingLiang', abbreviate: 'PL', initial: 'P'
        }, {
          cityName: '平顶山', spell: 'PingDingShan', abbreviate: 'PDS', initial: 'P'
        }, {
          cityName: '濮阳', spell: 'PuYang', abbreviate: 'PY', initial: 'P'
        }, {
          cityName: '萍乡', spell: 'PingXiang', abbreviate: 'PX', initial: 'P'
        }, {
          cityName: '盘锦', spell: 'PanJin', abbreviate: 'PJ', initial: 'P'
        }, {
          cityName: '普洱', spell: 'PuEr', abbreviate: 'PE', initial: 'P'
        }, {
          cityName: '平湖', spell: 'PingHu', abbreviate: 'PH', initial: 'P'
        }, {
          cityName: '平遥', spell: 'PingYao', abbreviate: 'PY', initial: 'P'
        }, {
          cityName: '齐齐哈尔', spell: 'QiQiHaEr', abbreviate: 'QQHE', initial: 'Q'
        }, {
          cityName: '且末', spell: 'QieMo', abbreviate: 'QM', initial: 'Q'
        }, {
          cityName: '庆阳', spell: 'QingYang', abbreviate: 'QY', initial: 'Q'
        }, {
          cityName: '衢州', spell: 'QuZhou', abbreviate: 'QZ', initial: 'Q'
        }, {
          cityName: '清远', spell: 'QingYuan', abbreviate: 'QY', initial: 'Q'
        }, {
          cityName: '钦州', spell: 'QinZhou', abbreviate: 'QZ', initial: 'Q'
        }, {
          cityName: '琼中', spell: 'QiongZhong', abbreviate: 'QZ', initial: 'Q'
        }, {
          cityName: '七台河', spell: 'QiTaiHe', abbreviate: 'QTH', initial: 'Q'
        }, {
          cityName: '潜江', spell: 'QianJiang', abbreviate: 'QJ', initial: 'Q'
        }, {
          cityName: '黔江', spell: 'QianJiang', abbreviate: 'QJ', initial: 'Q'
        }, {
          cityName: '启东', spell: 'QiDong', abbreviate: 'QD', initial: 'Q'
        }, {
          cityName: '曲靖', spell: 'QuJing', abbreviate: 'QJ', initial: 'Q'
        }, {
          cityName: '千岛湖', spell: 'QianDaoHu', abbreviate: 'QDH', initial: 'Q'
        }, {
          cityName: '黔西', spell: 'QianXi', abbreviate: 'QX', initial: 'Q'
        }, {
          cityName: '迁安', spell: 'QianAn', abbreviate: 'QA', initial: 'Q'
        }, {
          cityName: '曲阜', spell: 'QuFu', abbreviate: 'QF', initial: 'Q'
        }, {
          cityName: '泉州', spell: 'QuanZhou', abbreviate: 'QZ', initial: 'Q'
        }, {
          cityName: '秦皇岛', spell: 'QinHuangDao', abbreviate: 'QHD', initial: 'Q'
        }, {
          cityName: '青岛', spell: 'QingDao', abbreviate: 'QD', initial: 'Q'
        }, {
          cityName: '琼海', spell: 'QiongHai', abbreviate: 'QH', initial: 'Q'
        }, {
          cityName: '如皋', spell: 'RuGao', abbreviate: 'RG', initial: 'R'
        }, {
          cityName: '瑞安', spell: 'RuiAn', abbreviate: 'RA', initial: 'R'
        }, {
          cityName: '日照', spell: 'RiZhao', abbreviate: 'RZ', initial: 'R'
        }, {
          cityName: '日喀则', spell: 'RiKaZe', abbreviate: 'RKZ', initial: 'R'
        }, {
          cityName: '绥芬河', spell: 'SuiFenHe', abbreviate: 'SFH', initial: 'S'
        }, {
          cityName: '韶关', spell: 'ShaoGuan', abbreviate: 'SG', initial: 'S'
        }, {
          cityName: '上海浦东', spell: 'ShangHaiPuDong', abbreviate: 'SHPD', initial: 'S'
        }, {
          cityName: '上海虹桥', spell: 'ShangHaiHongQiao', abbreviate: 'SHHQ', initial: 'S'
        }, {
          cityName: '上海', spell: 'ShangHai', abbreviate: 'SH', initial: 'S'
        }, {
          cityName: '商丘', spell: 'ShangQiu', abbreviate: 'SQ', initial: 'S'
        }, {
          cityName: '绥化', spell: 'SuiHua', abbreviate: 'SH', initial: 'S'
        }, {
          cityName: '沈阳', spell: 'ShenYang', abbreviate: 'SY', initial: 'S'
        }, {
          cityName: '双鸭山', spell: 'ShuangYaShan', abbreviate: 'SYS', initial: 'S'
        }, {
          cityName: '山海关', spell: 'ShanHaiGuan', abbreviate: 'SHG', initial: 'S'
        }, {
          cityName: '随州', spell: 'SuiZhou', abbreviate: 'SZ', initial: 'S'
        }, {
          cityName: '邵阳', spell: 'ShaoYang', abbreviate: 'SY', initial: 'S'
        }, {
          cityName: '沙市', spell: 'ShaShi', abbreviate: 'SS', initial: 'S'
        }, {
          cityName: '四平', spell: 'SiPing', abbreviate: 'SP', initial: 'S'
        }, {
          cityName: '上饶', spell: 'ShangRao', abbreviate: 'SR', initial: 'S'
        }, {
          cityName: '宿迁', spell: 'SuQian', abbreviate: 'SQ', initial: 'S'
        }, {
          cityName: '石家庄', spell: 'ShiJiaZhuang', abbreviate: 'SJZ', initial: 'S'
        }, {
          cityName: '松原', spell: 'SongYuan', abbreviate: 'SY', initial: 'S'
        }, {
          cityName: '汕头', spell: 'ShanTou', abbreviate: 'ST', initial: 'S'
        }, {
          cityName: '石嘴山', spell: 'ShiZuiShan', abbreviate: 'SZS', initial: 'S'
        }, {
          cityName: '鄯善', spell: 'ShanShan', abbreviate: 'SS', initial: 'S'
        }, {
          cityName: '朔州', spell: 'ShuoZhou', abbreviate: 'SZ', initial: 'S'
        }, {
          cityName: '思茅', spell: 'SiMao', abbreviate: 'SM', initial: 'S'
        }, {
          cityName: '商洛', spell: 'ShangLuo', abbreviate: 'SL', initial: 'S'
        }, {
          cityName: '三亚', spell: 'SanYa', abbreviate: 'SY', initial: 'S'
        }, {
          cityName: '十堰', spell: 'ShiYan', abbreviate: 'SY', initial: 'S'
        }, {
          cityName: '顺德龙山', spell: 'ShunDeLongShan', abbreviate: 'SDLS', initial: 'S'
        }, {
          cityName: '苏州', spell: 'SuZhou', abbreviate: 'SZ', initial: 'S'
        }, {
          cityName: '三门峡', spell: 'SanMenXia', abbreviate: 'SMX', initial: 'S'
        }, {
          cityName: '深圳', spell: 'ShenZhen', abbreviate: 'SZ', initial: 'S'
        }, {
          cityName: '宿州', spell: 'SuZhou', abbreviate: 'SZ', initial: 'S'
        }, {
          cityName: '汕尾', spell: 'ShanWei', abbreviate: 'SW', initial: 'S'
        }, {
          cityName: '石河子', spell: 'ShiHeZi', abbreviate: 'SHZ', initial: 'S'
        }, {
          cityName: '神农架', spell: 'ShenNongJia', abbreviate: 'SNJ', initial: 'S'
        }, {
          cityName: '山南', spell: 'ShanNan', abbreviate: 'SN', initial: 'S'
        }, {
          cityName: '三门', spell: 'SanMen', abbreviate: 'SM', initial: 'S'
        }, {
          cityName: '嵊州', spell: 'ShengZhou', abbreviate: 'SZ', initial: 'S'
        }, {
          cityName: '石狮', spell: 'ShiShi', abbreviate: 'SS', initial: 'S'
        }, {
          cityName: '嵊泗', spell: 'ShengSi', abbreviate: 'SS', initial: 'S'
        }, {
          cityName: '三河', spell: 'SanHe', abbreviate: 'SH', initial: 'S'
        }, {
          cityName: '韶山', spell: 'ShaoShan', abbreviate: 'SS', initial: 'S'
        }, {
          cityName: '松潘', spell: 'SongPan', abbreviate: 'SP', initial: 'S'
        }, {
          cityName: '什邡', spell: 'ShenFang', abbreviate: 'SF', initial: 'S'
        }, {
          cityName: '上虞', spell: 'ShangYu', abbreviate: 'SY', initial: 'S'
        }, {
          cityName: '绍兴', spell: 'ShaoXing', abbreviate: 'SX', initial: 'S'
        }, {
          cityName: '遂宁', spell: 'SuiNing', abbreviate: 'SN', initial: 'S'
        }, {
          cityName: '厦门', spell: 'ShaMen', abbreviate: 'SM', initial: 'S'
        }, {
          cityName: '腾冲', spell: 'TengChong', abbreviate: 'TC', initial: 'T'
        }, {
          cityName: '吐鲁番', spell: 'TuLuFan', abbreviate: 'TLF', initial: 'T'
        }, {
          cityName: '唐山', spell: 'TangShan', abbreviate: 'TS', initial: 'T'
        }, {
          cityName: '塔城', spell: 'TaCheng', abbreviate: 'TC', initial: 'T'
        }, {
          cityName: '铜仁', spell: 'TongRen', abbreviate: 'TR', initial: 'T'
        }, {
          cityName: '通辽', spell: 'TongLiao', abbreviate: 'TL', initial: 'T'
        }, {
          cityName: '通化', spell: 'TongHua', abbreviate: 'TH', initial: 'T'
        }, {
          cityName: '天津', spell: 'TianJin', abbreviate: 'TJ', initial: 'T'
        }, {
          cityName: '太原', spell: 'TaiYuan', abbreviate: 'TY', initial: 'T'
        }, {
          cityName: '铜陵', spell: 'TongLing', abbreviate: 'TL', initial: 'T'
        }, {
          cityName: '屯昌', spell: 'TunChang', abbreviate: 'TC', initial: 'T'
        }, {
          cityName: '天门', spell: 'TianMen', abbreviate: 'TM', initial: 'T'
        }, {
          cityName: '铁岭', spell: 'TieLing', abbreviate: 'TL', initial: 'T'
        }, {
          cityName: '铜川', spell: 'TongChuan', abbreviate: 'TC', initial: 'T'
        }, {
          cityName: '泰州', spell: 'TaiZhou', abbreviate: 'TZ', initial: 'T'
        }, {
          cityName: '台州', spell: 'TaiZhou', abbreviate: 'TZ', initial: 'T'
        }, {
          cityName: '太仓', spell: 'TaiCang', abbreviate: 'TC', initial: 'T'
        }, {
          cityName: '桐庐', spell: 'TongLu', abbreviate: 'TL', initial: 'T'
        }, {
          cityName: '天台', spell: 'TianTai', abbreviate: 'TT', initial: 'T'
        }, {
          cityName: '台山', spell: 'TaiShan', abbreviate: 'TS', initial: 'T'
        }, {
          cityName: '天柱', spell: 'TianZhu', abbreviate: 'TZ', initial: 'T'
        }, {
          cityName: '天水', spell: 'TianShui', abbreviate: 'TS', initial: 'T'
        }, {
          cityName: '桐乡', spell: 'TongXiang', abbreviate: 'TX', initial: 'T'
        }, {
          cityName: '泰安', spell: 'TaiAn', abbreviate: 'TA', initial: 'T'
        }, {
          cityName: '乌兰浩特', spell: 'WuLanHaoTe', abbreviate: 'WLHT', initial: 'W'
        }, {
          cityName: '乌鲁木齐', spell: 'WuLuMuQi', abbreviate: 'WLMQ', initial: 'W'
        }, {
          cityName: '潍坊', spell: 'WeiFang', abbreviate: 'WF', initial: 'W'
        }, {
          cityName: '威海', spell: 'WeiHai', abbreviate: 'WH', initial: 'W'
        }, {
          cityName: '芜湖', spell: 'WuHu', abbreviate: 'WH', initial: 'W'
        }, {
          cityName: '文山', spell: 'WenShan', abbreviate: 'WS', initial: 'W'
        }, {
          cityName: '温州', spell: 'WenZhou', abbreviate: 'WZ', initial: 'W'
        }, {
          cityName: '乌海', spell: 'WuHai', abbreviate: 'WH', initial: 'W'
        }, {
          cityName: '武汉', spell: 'WuHan', abbreviate: 'WH', initial: 'W'
        }, {
          cityName: '武夷山', spell: 'WuYiShan', abbreviate: 'WYS', initial: 'W'
        }, {
          cityName: '无锡', spell: 'WuXi', abbreviate: 'WX', initial: 'W'
        }, {
          cityName: '梧州', spell: 'WuZhou', abbreviate: 'WZ', initial: 'W'
        }, {
          cityName: '万州', spell: 'WanZhou', abbreviate: 'WZ', initial: 'W'
        }, {
          cityName: '武威', spell: 'WuWei', abbreviate: 'WW', initial: 'W'
        }, {
          cityName: '五指山', spell: 'WuZhiShan', abbreviate: 'WZS', initial: 'W'
        }, {
          cityName: '文昌', spell: 'WenChang', abbreviate: 'WC', initial: 'W'
        }, {
          cityName: '吴忠', spell: 'WuZhong', abbreviate: 'WZ', initial: 'W'
        }, {
          cityName: '五家渠', spell: 'WuJiaQu', abbreviate: 'WJQ', initial: 'W'
        }, {
          cityName: '万宁', spell: 'WanNing', abbreviate: 'WN', initial: 'W'
        }, {
          cityName: '五台山', spell: 'WuTaiShan', abbreviate: 'WTS', initial: 'W'
        }, {
          cityName: '吴江', spell: 'WuJiang', abbreviate: 'WJ', initial: 'W'
        }, {
          cityName: '武义', spell: 'WuYi', abbreviate: 'WY', initial: 'W'
        }, {
          cityName: '温岭', spell: 'WenLing', abbreviate: 'WL', initial: 'W'
        }, {
          cityName: '武穴', spell: 'WuXue', abbreviate: 'WX', initial: 'W'
        }, {
          cityName: '婺源', spell: 'WuYuan', abbreviate: 'WY', initial: 'W'
        }, {
          cityName: '渭南', spell: 'WeiNan', abbreviate: 'WN', initial: 'W'
        }, {
          cityName: '乌兰察布', spell: 'WuLanChaBu', abbreviate: 'WLCB', initial: 'W'
        }, {
          cityName: '武当山', spell: 'WuDangShan', abbreviate: 'WDS', initial: 'W'
        }, {
          cityName: '西双版纳', spell: 'XiShuangBanNa', abbreviate: 'XSBN', initial: 'X'
        }, {
          cityName: '兴义', spell: 'XingYi', abbreviate: 'XY', initial: 'X'
        }, {
          cityName: '西安', spell: 'XiAn', abbreviate: 'XA', initial: 'X'
        }, {
          cityName: '兴城', spell: 'XingCheng', abbreviate: 'XC', initial: 'X'
        }, {
          cityName: '襄樊', spell: 'XiangFan', abbreviate: 'XF', initial: 'X'
        }, {
          cityName: '西昌', spell: 'XiChang', abbreviate: 'XC', initial: 'X'
        }, {
          cityName: '锡林浩特', spell: 'XiLinHaoTe', abbreviate: 'XLHT', initial: 'X'
        }, {
          cityName: '兴宁', spell: 'XingNing', abbreviate: 'XN', initial: 'X'
        }, {
          cityName: '咸阳', spell: 'XianYang', abbreviate: 'XY', initial: 'X'
        }, {
          cityName: '西宁', spell: 'XiNing', abbreviate: 'XN', initial: 'X'
        }, {
          cityName: '邢台', spell: 'XingTai', abbreviate: 'XT', initial: 'X'
        }, {
          cityName: '徐州', spell: 'XuZhou', abbreviate: 'XZ', initial: 'X'
        }, {
          cityName: '宣城', spell: 'XuanCheng', abbreviate: 'XC', initial: 'X'
        }, {
          cityName: '许昌', spell: 'XuChang', abbreviate: 'XC', initial: 'X'
        }, {
          cityName: '信阳', spell: 'XinYang', abbreviate: 'XY', initial: 'X'
        }, {
          cityName: '新乡', spell: 'XinXiang', abbreviate: 'XX', initial: 'X'
        }, {
          cityName: '孝感', spell: 'XiaoGan', abbreviate: 'XG', initial: 'X'
        }, {
          cityName: '咸宁', spell: 'XianNing', abbreviate: 'XN', initial: 'X'
        }, {
          cityName: '仙桃', spell: 'XianTao', abbreviate: 'XT', initial: 'X'
        }, {
          cityName: '湘西', spell: 'XiangXi', abbreviate: 'XX', initial: 'X'
        }, {
          cityName: '湘潭', spell: 'XiangTan', abbreviate: 'XT', initial: 'X'
        }, {
          cityName: '忻州', spell: 'XinZhou', abbreviate: 'XZ', initial: 'X'
        }, {
          cityName: '襄阳', spell: 'XiangYang', abbreviate: 'XY', initial: 'X'
        }, {
          cityName: '象山', spell: 'XiangShan', abbreviate: 'XS', initial: 'X'
        }, {
          cityName: '新昌', spell: 'XinChang', abbreviate: 'XC', initial: 'X'
        }, {
          cityName: '兴安', spell: 'XingAn', abbreviate: 'XA', initial: 'X'
        }, {
          cityName: '兴隆', spell: 'XingLong', abbreviate: 'XL', initial: 'X'
        }, {
          cityName: '新余', spell: 'XinYu', abbreviate: 'XY', initial: 'X'
        }, {
          cityName: '夏河', spell: 'XiaHe', abbreviate: 'XH', initial: 'X'
        }, {
          cityName: '玉树', spell: 'YuShu', abbreviate: 'YS', initial: 'Y'
        }, {
          cityName: '伊春', spell: 'YiChun', abbreviate: 'YC', initial: 'Y'
        }, {
          cityName: '延安', spell: 'YanAn', abbreviate: 'YA', initial: 'Y'
        }, {
          cityName: '银川', spell: 'YinChuan', abbreviate: 'YC', initial: 'Y'
        }, {
          cityName: '永州', spell: 'YongZhou', abbreviate: 'YZ', initial: 'Y'
        }, {
          cityName: '榆林', spell: 'YuLin', abbreviate: 'YL', initial: 'Y'
        }, {
          cityName: '宜宾', spell: 'YiBin', abbreviate: 'YB', initial: 'Y'
        }, {
          cityName: '运城', spell: 'YunCheng', abbreviate: 'YC', initial: 'Y'
        }, {
          cityName: '宜昌', spell: 'YiChang', abbreviate: 'YC', initial: 'Y'
        }, {
          cityName: '伊宁', spell: 'YiNing', abbreviate: 'YN', initial: 'Y'
        }, {
          cityName: '义乌', spell: 'YiWu', abbreviate: 'YW', initial: 'Y'
        }, {
          cityName: '依兰', spell: 'YiLan', abbreviate: 'YL', initial: 'Y'
        }, {
          cityName: '延吉', spell: 'YanJi', abbreviate: 'YJ', initial: 'Y'
        }, {
          cityName: '烟台', spell: 'YanTai', abbreviate: 'YT', initial: 'Y'
        }, {
          cityName: '盐城', spell: 'YanCheng', abbreviate: 'YC', initial: 'Y'
        }, {
          cityName: '元谋', spell: 'YuanMou', abbreviate: 'YM', initial: 'Y'
        }, {
          cityName: '营口', spell: 'YingKou', abbreviate: 'YK', initial: 'Y'
        }, {
          cityName: '宜春', spell: 'YiChun', abbreviate: 'YC', initial: 'Y'
        }, {
          cityName: '阳江', spell: 'YangJiang', abbreviate: 'YJ', initial: 'Y'
        }, {
          cityName: '云浮', spell: 'YunFu', abbreviate: 'YF', initial: 'Y'
        }, {
          cityName: '岳阳', spell: 'YueYang', abbreviate: 'YY', initial: 'Y'
        }, {
          cityName: '益阳', spell: 'YiYang', abbreviate: 'YY', initial: 'Y'
        }, {
          cityName: '鹰潭', spell: 'YingTan', abbreviate: 'YT', initial: 'Y'
        }, {
          cityName: '阳泉', spell: 'YangQuan', abbreviate: 'YQ', initial: 'Y'
        }, {
          cityName: '雅安', spell: 'YaAn', abbreviate: 'YA', initial: 'Y'
        }, {
          cityName: '扬州', spell: 'YangZhou', abbreviate: 'YZ', initial: 'Y'
        }, {
          cityName: '玉溪', spell: 'YuXi', abbreviate: 'YX', initial: 'Y'
        }, {
          cityName: '宜兴', spell: 'YiXing', abbreviate: 'YX', initial: 'Y'
        }, {
          cityName: '仪征', spell: 'YiZheng', abbreviate: 'YZ', initial: 'Y'
        }, {
          cityName: '永康', spell: 'YongKang', abbreviate: 'YK', initial: 'Y'
        }, {
          cityName: '阳朔', spell: 'YangShuo', abbreviate: 'YS', initial: 'Y'
        }, {
          cityName: '余杭', spell: 'YuHang', abbreviate: 'YH', initial: 'Y'
        }, {
          cityName: '余姚', spell: 'YuYao', abbreviate: 'YY', initial: 'Y'
        }, {
          cityName: '湛江', spell: 'ZhanJiang', abbreviate: 'ZJ', initial: 'Z'
        }, {
          cityName: '珠海', spell: 'ZhuHai', abbreviate: 'ZH', initial: 'Z'
        }, {
          cityName: '遵义', spell: 'ZunYi', abbreviate: 'ZY', initial: 'Z'
        }, {
          cityName: '长白山', spell: 'ZhangBaiShan', abbreviate: 'ZBS', initial: 'Z'
        }, {
          cityName: '中卫', spell: 'ZhongWei', abbreviate: 'ZW', initial: 'Z'
        }, {
          cityName: '郑州', spell: 'ZhengZhou', abbreviate: 'ZZ', initial: 'Z'
        }, {
          cityName: '长春', spell: 'ZhangChun', abbreviate: 'ZC', initial: 'Z'
        }, {
          cityName: '长治', spell: 'ZhangZhi', abbreviate: 'ZZ', initial: 'Z'
        }, {
          cityName: '重庆', spell: 'ZhongQing', abbreviate: 'ZQ', initial: 'Z'
        }, {
          cityName: '长海', spell: 'ZhangHai', abbreviate: 'ZH', initial: 'Z'
        }, {
          cityName: '长沙', spell: 'ZhangSha', abbreviate: 'ZS', initial: 'Z'
        }, {
          cityName: '张家界', spell: 'ZhangJiaJie', abbreviate: 'ZJJ', initial: 'Z'
        }, {
          cityName: '舟山', spell: 'ZhouShan', abbreviate: 'ZS', initial: 'Z'
        }, {
          cityName: '昭通', spell: 'ZhaoTong', abbreviate: 'ZT', initial: 'Z'
        }, {
          cityName: '张掖', spell: 'ZhangYe', abbreviate: 'ZY', initial: 'Z'
        }, {
          cityName: '重庆舟白', spell: 'ZhongQingZhouBai', abbreviate: 'ZQZB', initial: 'Z'
        }, {
          cityName: '中山', spell: 'ZhongShan', abbreviate: 'ZS', initial: 'Z'
        }, {
          cityName: '肇庆', spell: 'ZhaoQing', abbreviate: 'ZQ', initial: 'Z'
        }, {
          cityName: '周口', spell: 'ZhouKou', abbreviate: 'ZK', initial: 'Z'
        }, {
          cityName: '自贡', spell: 'ZiGong', abbreviate: 'ZG', initial: 'Z'
        }, {
          cityName: '资阳', spell: 'ZiYang', abbreviate: 'ZY', initial: 'Z'
        }, {
          cityName: '漳州', spell: 'ZhangZhou', abbreviate: 'ZZ', initial: 'Z'
        }, {
          cityName: '株洲', spell: 'ZhuZhou', abbreviate: 'ZZ', initial: 'Z'
        }, {
          cityName: '张家口', spell: 'ZhangJiaKou', abbreviate: 'ZJK', initial: 'Z'
        }, {
          cityName: '芷江', spell: 'ZhiJiang', abbreviate: 'ZJ', initial: 'Z'
        }, {
          cityName: '张家港', spell: 'ZhangJiaGang', abbreviate: 'ZJG', initial: 'Z'
        }, {
          cityName: '增城', spell: 'ZengCheng', abbreviate: 'ZC', initial: 'Z'
        }, {
          cityName: '驻马店', spell: 'ZhuMaDian', abbreviate: 'ZMD', initial: 'Z'
        }, {
          cityName: '中江', spell: 'ZhongJiang', abbreviate: 'ZJ', initial: 'Z'
        }, {
          cityName: '诸暨', spell: 'ZhuJi', abbreviate: 'ZJ', initial: 'Z'
        }, {
          cityName: '淄博', spell: 'ZiBo', abbreviate: 'ZB', initial: 'Z'
        }, {
          cityName: '枣庄', spell: 'ZaoZhuang', abbreviate: 'ZZ', initial: 'Z'
        }, {
          cityName: '镇江', spell: 'ZhenJiang', abbreviate: 'ZJ', initial: 'Z'
        }
        ],
        selectCity: []
      }
    },
    methods: {
      handleClick (tab, event) {
      },
      discolor () { // 全部地区窗体添加鼠标移入 移出效果
        var div = document.getElementsByClassName('city-content bg-purple')
        for (let i = 0; i < div.length; i++) {
          div[i].setAttribute('onmouseover', "this.style='color: #F7BA2A;'")
          div[i].setAttribute('onmouseout', "this.style='color: #1F2D3D'")
        }
      },
      indication (event) { // 根据input是否有值来确定显示窗体
        if (this.input === '') {
          this.isShowCityBody = true // 显示
          this.isShowCityNameBody = false // 隐藏
        } else {
          this.vagueQuery() // 模糊查询
          this.isShowCityBody = false // 隐藏
          this.isShowCityNameBody = true // 显示
        }
      },
      conceal (event) { // 隐藏地区窗体
        this.isShowCityBody = false // 隐藏
        this.isShowCityNameBody = false // 隐藏
      },
      downSelect (event) { // 按键↓事件
        if (this.input !== '') {
          var div = document.getElementsByClassName('city-select')
          div[this.keyIndex].setAttribute('style', '')
          if (this.keyIndex === div.length - 1) {
            this.keyIndex = 0
          } else {
            this.keyIndex = this.keyIndex + 1
          }
          div[this.keyIndex].setAttribute('style', 'background-color: #bfcbd9')
        }
      },
      upSelect (event) { // 按键↑事件
        if (this.input !== '') {
          var div = document.getElementsByClassName('city-select')
          div[this.keyIndex].setAttribute('style', '')
          if (this.keyIndex === 0) {
            this.keyIndex = div.length
          }
          this.keyIndex = this.keyIndex - 1
          div[this.keyIndex].setAttribute('style', 'background-color: #bfcbd9')
        }
      },
      enterSelect (event) { // 回车事件
        if (this.input !== '') {
          var div = document.getElementsByClassName('city-name')
          this.input = div[this.keyIndex].innerHTML.trim()
          this.isShowCityNameBody = false // 隐藏
        }
      },
      evaluationInput (cityName) { // 赋值隐藏窗体
        this.input = cityName
        this.isShowCityBody = false // 隐藏
        this.isShowCityNameBody = false // 隐藏
      },
      vagueQuery () { // 模糊查询方法
        if (this.input !== '') {
          this.selectCity = []
          var reg = new RegExp('^' + this.input + '|' + this.input, 'gi')
          var arr = []
          for (var i = 0; i < this.city.length; i++) {
            if (reg.test(this.city[i].cityName + '|' + this.city[i].spell + '|' + this.city[i].abbreviate)) {
              arr.push(this.city[i])
              this.selectCity = arr
              if (arr.length > 10) {
                break
              }
            }
          }
          if (this.keyIndex > 0) {
            var div = document.getElementsByClassName('city-select')
            div[this.keyIndex].setAttribute('style', '')
            div[0].setAttribute('style', 'background-color: #bfcbd9')
          }
          this.keyIndex = 0
        }
      },
      evaluation (cityName) { // 选中赋值
        this.input = cityName
        this.isShowCityBody = false // 隐藏
        this.isShowCityNameBody = false // 隐藏
      },
      mover (index) { // 鼠标移动效果
        var div = document.getElementsByClassName('city-select')
        div[this.keyIndex].setAttribute('style', '')
        div[index].setAttribute('style', 'background-color: #bfcbd9')
        this.keyIndex = index
      }
    },
    mounted () {
      this.discolor()
      this.isShowCityBody = false // 隐藏
      this.isShowCityNameBody = false // 隐藏
      document.onclick = function (event) { // 点击控件以外的地方隐藏弹框
        if (!(event.target.name === 'city' || event.target.innerHTML === '热门' || event.target.innerHTML === 'ABCD' || event.target.innerHTML === 'EFGH' || event.target.innerHTML === 'JKL' || event.target.innerHTML === 'MNPQ' || event.target.innerHTML === 'STW' || event.target.innerHTML === 'XYZ')) { // 合适条件{
          this.isShowCityBody = false // 隐藏
          this.isShowCityNameBody = false // 隐藏
        }
      }
      if (this.initCity) {
        this.input = this.initCity
      } else {
        if (!this.flag) {
          // 获取当前所属城市
          var that = this
          $.ajax({
            url: 'http://ip.chinaz.com/getip.aspx',
            dataType: 'jsonp',
            data: '',
            jsonp: 'callback',
            success: function (data) {
              let city = data.address
              if (city.indexOf('省') > 0 && city.indexOf('市') > 0) {
                let indexprovice = city.indexOf('省')
                let indexcity = city.indexOf('市')
                that.input = city.substring(indexprovice + 1, indexcity)
              } else if (city.indexOf('省') === -1 && city.indexOf('市') > 0) {
                let indexcity = city.indexOf('市')
                that.input = city.substring(0, indexcity)
              }
            }
          })
        }
      }
    }
  }
</script>

<style lang="stylus" rel="stylesheet/stylus" scoped>
  #cityBody {
    border: 1px solid #bfcbd9;
    border-radius: 4px;
    width: 600px;
    background-color: #fff;
    position: relative;
    font-size: 12px;
    z-index 10;
  }

  #cityNameBody {
    border: 1px solid #bfcbd9;
    border-radius: 4px;
    width: 260px;
    background-color: #fff;
    position: relative;
    font-size: 12px;
    z-index 10;
  }

  .city-name {
    margin-left: 5px;
    float: left;
    line-height: 25px;
    height: 25px;
  }

  .city-spell {
    margin-right: 5px;
    float: right;
    line-height: 25px;
    height: 25px;
  }

  .city-select {
    margin-top: 5px;
    clear: both;
    height: 25px;
    width: 99%;
    border-radius: 4px;
    cursor: pointer;
  }

  .city-content {
    border-radius: 4px;
    height: 28px;
    text-align: left;
    cursor: pointer;
  }

  .bg-purple {
    float: left;
    width: 70px;
    white-space: nowrap;
    text-overflow: ellipsis;
    -o-text-overflow: ellipsis;
    overflow: hidden;
  }

  .city-frist {
    float: left;
    width: 20px;
    color: #F7BA2A;
    height: 100%
  }

  .city-div {
    width: 600px;
    clear: both;
    position: relative;
  }
</style>
